import Doc from '~/components/layout/docs'

export const meta = {
  title: 'Regions and Providers',
  description:
    'A listing and explanation of the regions and providers ZEIT Now implements.',
  editUrl: 'pages/docs/v2/network/regions-and-providers.mdx',
  lastEdited: '2020-01-29T14:43:14.000Z'
}

A typical server configuration might begin by selecting the region where the physical server is located. A local business would have no issue selecting the closest region to their store, but businesses with traffic spanning cities, countries, or even the entire globe might struggle to serve all their customers. This is where the ZEIT Smart CDN comes in.

## Origin vs Edge Regions

Edge Regions are restricted to serving static files or cached responses from Serverless Functions. Origin Regions do not have this restriction and can therefore host Serverless Functions.

When an application is deployed to ZEIT Now, it automatically serves static files and caches responses in [all Regions](#routing) (both Origin and Edge) across the globe. The developer can choose which Origin Regions to deploy Serverless Functions to by using `--regions` in Now CLI or the [`regions` key](/docs/configuration#project/regions) in a `now.json` file.

When choosing Origin Regions, consider where your database (if any) is located and choose the Origin Regions closest to where the data is stored.

## Providers

Most applications developed in the cloud only ever see one cloud. When using ZEIT Now, the sky's the limit. Our CDN abstracts away cloud providers like Amazon Web Services and Google Cloud Platform. The most exciting benefit of multi-cloud is that you do not rely solely on a single cloud provider, providing far greater reliability.

## Outage Resiliency

If an Edge Region goes down, an application's traffic gets rerouted to another Edge Region. If an Origin Region goes down, anything deployed to that Region automatically gets redeployed in a healthy Region.

To further increase our coverage and resiliency, we plan to utilize more cloud providers in the future and continue expanding our Regions.

## Routing

The ZEIT Now Platform acts as a Universal API and Overlay Network on top of existing cloud infrastructure providers.

| Region ID | Reference Location        | Provider Region (Routing)   | Provider Region (Now Serverless Functions) | Origin/Edge |
| --------- | ------------------------- | --------------------------- | ------------------------------------------ | ----------- |
| arn1      | Stockholm, Sweden         | AWS eu-north-1              | AWS eu-north-1                             | Origin      |
| bom1      | Mumbai, India             | AWS ap-south-1              | AWS ap-south-1                             | Origin      |
| bru1      | Brussels, Belgium, Europe | GCP europe-west1            | AWS eu-central-1                           | Origin      |
| cdg1      | Paris, France, Europe     | AWS eu-west-3               | AWS eu-west-3                              | Origin      |
| chs1      | Charleston, East US       | GCP us-east1                | n/a                                        | Edge        |
| cle1      | Cleveland, East US        | AWS us-east-2               | AWS us-east-2                              | Origin      |
| dub1      | Dublin, Ireland           | AWS eu-west-1               | AWS eu-west-1                              | Origin      |
| gru1      | São Paulo, Brazil         | AWS sa-east-1               | AWS sa-east-1                              | Origin      |
| hel1      | Helsinki, Finland         | GCP europe-north1           | n/a                                        | Edge        |
| hkg1      | Hong Kong                 | GCP asia-east2              | n/a                                        | Edge        |
| hnd1      | Tokyo, Japan              | AWS ap-northeast-1          | AWS ap-northeast-1                         | Origin      |
| iad1      | Washington DC, USA        | AWS us-east-1               | AWS us-east-1                              | Origin      |
| icn1      | Seoul, South Korea        | AWS ap-northeast-2          | AWS ap-northeast-2                         | Origin      |
| lax1      | Los Angeles, West US      | GCP us-west2                | n/a                                        | Edge        |
| lhr1      | London, UK                | AWS eu-west-2               | AWS eu-west-2                              | Origin      |
| oma1      | Omaha, Central US         | GCP us-central1             | n/a                                        | Edge        |
| pdx1      | Portland, West US         | AWS us-west-2               | AWS us-west-2                              | Origin      |
| sfo1      | San Francisco, CA, USA    | AWS us-west-1               | AWS us-west-1                              | Origin      |
| sin1      | Singapore                 | AWS ap-southeast-1          | AWS ap-southeast-1                         | Origin      |
| syd1      | Sydney, Australia         | AWS ap-southeast-2          | AWS ap-southeast-2                         | Origin      |
| tpe1      | Taipei, Taiwan            | GCP asia-east1              | n/a                                        | Edge        |
| yul1      | Montreal, Canada          | GCP northamerica-northeast1 | n/a                                        | Edge        |
| zrh1      | Zurich, Switzerland       | GCP europe-west6            | n/a                                        | Edge        |

During development via `now dev`, the region is assigned `dev1` to mimic the ZEIT Now Platform infrastructure.

| Region ID | Reference Location |
| --------- | ------------------ |
| dev1      | localhost          |

export default ({ children }) => <Doc meta={meta}>{children}</Doc>

export const config = {
  amp: 'hybrid'
}
